package com.hejing.project03_优尚开发团队人员调度系统.domain;

/**
 * ClassName: Employee
 * Package: com.hejing.project03_优尚开发团队人员调度系统.domain
 * Description:
 *
 * @Author: HeJing
 * @Create: 2023-04-12 10:57
 * @Version: 1.0
 */
public class Employee {

    // 属性
    private int id;         // 员工号
    private String name;    // 员工姓名
    private int age;        // 员工年龄
    private double salary;  // 员工薪水

    // 构造器
    public Employee(){

    }

    public Employee(int id, String name, int age, double salary){
        this.id = id;
        this.name = name;
        this.age = age;
        this.salary = salary;
    }

    // get set

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public double getSalary() {
        return salary;
    }

    public void setSalary(double salary) {
        this.salary = salary;
    }

    // 提供共用
    protected String getDetails(){
        return id + "\t" + name + "\t" + age + "\t" + salary;
    }

    @Override
    public String toString(){
        return getDetails();
    }
}































